package com.huanong.pojo;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * 管理员实体表映射
 */
public class Admin {

    //主键id
    private Integer anId;

    //管理员名字
    private String anName;

    //管理员性别
    private String anSex;

    //管理员年龄
    private Integer anAge;

    //管理员账号
    private String anAccount;

    //管理员密码
    private String anPassword;

    //管理员注册时间
    private Date anTime;

    private String anTimeStr;

    public String getAnTimeStr() {
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        anTimeStr = simpleDateFormat.format(anTime);

        return anTimeStr;
    }

    public Integer getAnId() {
        return anId;
    }

    public void setAnId(Integer anId) {
        this.anId = anId;
    }

    public String getAnName() {
        return anName;
    }

    public void setAnName(String anName) {
        this.anName = anName;
    }

    public String getAnSex() {
        return anSex;
    }

    public void setAnSex(String anSex) {
        this.anSex = anSex;
    }

    public Integer getAnAge() {
        return anAge;
    }

    public void setAnAge(Integer anAge) {
        this.anAge = anAge;
    }

    public String getAnAccount() {
        return anAccount;
    }

    public void setAnAccount(String anAccount) {
        this.anAccount = anAccount;
    }

    public String getAnPassword() {
        return anPassword;
    }

    public void setAnPassword(String anPassword) {
        this.anPassword = anPassword;
    }

    public Date getAnTime() {
        return anTime;
    }

    public void setAnTime(Date anTime) {
        this.anTime = anTime;
    }

    @Override
    public String toString() {
        return "admin{" +
                "anId=" + anId +
                ", anName='" + anName + '\'' +
                ", anSex='" + anSex + '\'' +
                ", anAge=" + anAge +
                ", anAccount='" + anAccount + '\'' +
                ", anPassword='" + anPassword + '\'' +
                ", anTime='" + anTime + '\'' +
                '}';
    }
}
